<%@ page language="C#" masterpagefile="~/MasterPage.master" autoeventwireup="true" inherits="Gestion_Default, App_Web_r76-jnnk" title="Untitled Page" %>
<asp:Content ID="Content1" ContentPlaceHolderID="contenido" Runat="Server">
    <table width="100%">
        <tr>
            <td align="left" colspan="1" style="width: 400px; height: 14px; text-align: left"
                valign="top">
                <strong>Ordenes Ingresadas</strong></td>
            <td align="left" colspan="1" style="width: 10px; height: 14px; text-align: left"
                valign="top">
            </td>
            <td align="left" colspan="2" style="height: 14px; text-align: left" valign="top">
                <strong>Datos generales<br />
                </strong>
            </td>
            <td align="left" colspan="1" style="width: 100px; height: 14px; text-align: left"
                valign="top">
            </td>
        </tr>
        <tr>
            <td align="left" colspan="1" rowspan="7" style="width: 400px; text-align: left" valign="top">
                <asp:GridView ID="gdvOrdenesDeTrabajo" runat="server" AutoGenerateColumns="False"
                    DataKeyNames="Id" OnSelectedIndexChanged="gdvOrdenesDeTrabajo_SelectedIndexChanged"
                    Width="100%" EmptyDataText="No hay ordenes">
                    <RowStyle CssClass="RowStyle" />
                    <Columns>
                        <asp:TemplateField HeaderText="N&#176;" SortExpression="NumeroOrdenDeTrabajo">
                            <EditItemTemplate>
                                <asp:TextBox ID="TextBox1" runat="server" Text='<%# Bind("NumeroOrdenDeTrabajo") %>'></asp:TextBox>
                            </EditItemTemplate>
                            <ItemTemplate>
                                <asp:Label ID="Label1" runat="server" Text='<%# Bind("NumeroOrdenDeTrabajo") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Fecha" SortExpression="Fecha">
                            <EditItemTemplate>
                                <asp:TextBox ID="TextBox2" runat="server" Text='<%# Bind("Fecha") %>'></asp:TextBox>
                            </EditItemTemplate>
                            <ItemTemplate>
                                <asp:Label ID="Label2" runat="server" Text='<%# Bind("Fecha", "{0:d}") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:TemplateField HeaderText="Cliente" SortExpression="Cliente">
                            <EditItemTemplate>
                                <asp:TextBox ID="TextBox3" runat="server" Text='<%# Bind("[Cliente.RazonSocial]") %>'></asp:TextBox>
                            </EditItemTemplate>
                            <ItemTemplate>
                                <asp:Label ID="Label3" runat="server" Text='<%# Eval("Cliente.RazonSocial") %>'></asp:Label>
                            </ItemTemplate>
                        </asp:TemplateField>
                        <asp:CommandField SelectText="Seleccionar" ShowSelectButton="True" />
                    </Columns>
                    <PagerStyle CssClass="PagerStyle" />
                    <SelectedRowStyle CssClass="SelectedRowStyle" />
                    <HeaderStyle CssClass="HeaderStyle" />
                    <AlternatingRowStyle CssClass="AltRowStyle" />
                    <EmptyDataRowStyle HorizontalAlign="Center" VerticalAlign="Middle" />
                </asp:GridView>
            </td>
            <td align="left" colspan="1" style="width: 10px; text-align: right" valign="top">
            </td>
            <td align="left" colspan="1" style="width: 100px; text-align: right" valign="top">
                    Numero OT :</td>
            <td align="left" colspan="1" style="width: 210px" valign="top">
                    <asp:Label ID="lblNumero" runat="server" Width="100%"></asp:Label></td>
            <td align="left" colspan="1" style="width: 100px" valign="top">
                <asp:Button ID="btnAprobar" runat="server" Text="Aprobar" CssClass="botonAceptar" Height="21px" OnClick="btnAprobar_Click" Width="80px" /></td>
        </tr>
        <tr>
            <td align="left" colspan="1" style="width: 10px; text-align: right" valign="top">
            </td>
            <td align="left" colspan="1" style="width: 100px; text-align: right" valign="top">
                    Cliente :<br />
            </td>
            <td align="left" colspan="1" style="width: 210px; text-align: left" valign="top">
                    <asp:Label ID="lblCliente" runat="server" Width="100%"></asp:Label></td>
            <td align="left" colspan="1" style="width: 100px; text-align: left" valign="top">
                <asp:Button ID="btnRechazar" runat="server" Text="Rechazar" CssClass="botonCancelar" Height="21px" OnClick="btnRechazar_Click" Width="80px" /></td>
        </tr>
        <tr>
            <td align="left" colspan="1" style="width: 10px; text-align: right" valign="top">
            </td>
            <td align="left" colspan="1" style="width: 100px; text-align: right" valign="top">
                    Descripcion :</td>
            <td align="left" colspan="1" style="width: 210px; text-align: left" valign="top">
                    <asp:Label ID="lblDescripcion" runat="server" Height="100%" Width="100%"></asp:Label></td>
            <td align="left" colspan="1" style="width: 100px; text-align: left" valign="top">
            </td>
        </tr>
        <tr>
            <td align="left" colspan="1" style="width: 10px; text-align: right" valign="top">
            </td>
            <td align="left" colspan="1" style="width: 100px; text-align: right" valign="top">
                Monto :</td>
            <td align="left" colspan="1" style="width: 210px; text-align: left" valign="top">
                <asp:Label ID="lblMonto" runat="server" Width="100%"></asp:Label></td>
            <td align="left" colspan="1" style="width: 100px; text-align: left" valign="top">
            </td>
        </tr>
        <tr>
            <td align="left" colspan="1" style="width: 10px; text-align: left" valign="top">
            </td>
            <td align="left" colspan="2" style="text-align: left" valign="top">
                <strong>Productos Asociados<br />
                </strong>
            </td>
            <td align="left" colspan="1" style="width: 100px; text-align: left" valign="top">
            </td>
        </tr>
        <tr>
            <td align="left" colspan="1" style="width: 10px; text-align: left" valign="top">
            </td>
            <td align="left" colspan="3" style="text-align: left" valign="top">
                    <asp:DataList ID="dtlDetalleOrdenDeTrabajo" runat="server" Width="100%">
                        <HeaderTemplate>
                            <table width="100%" class="HeaderStyle">
                                <tr>
                                    <td style="width: 80%; text-align: left">
                                        Producto</td>
                                    <td style="width: 20%; text-align: left">
                                        Cantidad</td>
                                </tr>
                            </table>
                            <hr />
                        </HeaderTemplate>
                        <ItemTemplate>
                            <table style="border-right-style: none; border-right-color: black" width="100%">
                                <tr>
                                    <td style="width: 80%; text-align: left">
                                        <asp:Label ID="ProductoLabel" runat="server" Text='<%# Eval("Producto.Descripcion") %>'></asp:Label></td>
                                    <td align="right" style="width: 20%; text-align: right">
                                        <asp:Label ID="CantidadIngresoLabel" runat="server" Text='<%# Eval("Cantidad") %>'></asp:Label></td>
                                </tr>
                            </table>
                        </ItemTemplate>
                        <SeparatorStyle BorderColor="Black" BorderStyle="Solid" />
                    </asp:DataList>&nbsp;
            </td>
        </tr>
        <tr>
            <td align="left" colspan="1" style="width: 10px; text-align: left" valign="top">
            </td>
            <td align="left" colspan="3" style="text-align: left" valign="top">
            </td>
        </tr>
    </table>
    &nbsp; &nbsp; &nbsp; &nbsp;
    &nbsp; &nbsp;&nbsp;
</asp:Content>

